package com.dutao.designpattern.c_builder;

import com.dutao.designpattern.a_factory.normalfactory.MailSender;
import com.dutao.designpattern.a_factory.normalfactory.Sender;
import com.dutao.designpattern.a_factory.normalfactory.SmsSender;

import java.util.ArrayList;
import java.util.List;

public class Builder {

  private List<Sender> list = new ArrayList<Sender>();

  public void produceMailSender(int count){
    for(int i=0; i<count; i++){
      list.add(new MailSender());
    }
  }

  public void produceSmsSender(int count){
    for(int i=0; i<count; i++){
      list.add(new SmsSender());
    }
  }
}
